﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace NewRen.Models.ViewModel
{
    public class vIntegration
    {
        public int ID { get; set; }

        /// <summary>
        /// 用户id
        /// </summary>
        public int UserID { get; set; }

        /// <summary>
        /// 收支积分
        /// </summary>
        public double Integration { get; set; }

        /// <summary>
        /// 收支类型
        /// </summary>
        public TransactionType Transaction { get; set; }

        /// <summary>
        /// 日期
        /// </summary>
        public DateTime Time { get; set; }

        /// <summary>
        /// 产品id
        /// </summary>
        public int? ProductID { get; set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string Hint { get; set; }
        public byte[] Picture { get; set; }
        
        public vIntegration(){}
        public vIntegration(IntegrationRecord model)
        {
            DB db = new DB();
            this.ID = model.ID;
            this.UserID = model.UserID;
            this.Integration = model.Integration;
            this.Transaction = model.Transaction;
            this.ProductID = model.ProductID;
            this.Hint = model.Hint;
            this.Time = model.Time;

        }
    }
}
   